﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel.DataAnnotations;
using Proggy.Web.Cms.ContentModel;

namespace Proggy.Web.Cms.PropertyTypes
{
    /// <summary>
    /// The interface for property types
    /// </summary>
    public interface IValidatablePropertyType
    {
        /// <summary>
        /// Checks if property is valid based on values and validation context
        /// </summary>
        /// <param name="vContext"></param>
        /// <returns></returns>
        Tuple<bool, string> GetIsValid(ValidationContext vContext, ContentModelPropertyTypeAttribute attr);
    }
}
